/*
-----------------------------------------------------------------------------
Filename:    Projectile.h
Author: Michael Sebright
-----------------------------------------------------------------------------
Defines the general projectile object
Base class for all projectile objects
*/

#ifndef __Projectile_H__
#define __Projectile_H__

#include "Ogre.h"

using namespace Ogre;


class Projectile {
protected:
	double velocity;       // velocity of projectile
	Quaternion direction;  // direction projectile is traveling 
	Degree accuracy;       // degree offset bullet travels off initial direction 
	bool isActive;         // flag for if bullet is traveling on screen

	SceneNode* mProjectileNode; 
	ManualObject* mProjectileObj;
	
	SYSTEMTIME systemTime;  // System time for ramdomization 

private:
	void setUpProjectile(SceneManager* sceneMgr);

public:
	Projectile();
	Projectile(SceneManager* sceneMgr);
	void fire(Vector3 initialPosisition, Quaternion direction);
	void update(Real deltaTime, Camera* cam);
	bool isProjectileActive();
};

#endif